const token = "helowin_token";
const user = "user";

export function getUser() {
    return JSON.parse(sessionStorage.getItem(user))
}

export function setUser(value) {
    sessionStorage.setItem(user, JSON.stringify(value))
}

export function removeUser() {
    sessionStorage.removeItem(user);
}

export function getToken() {
    return sessionStorage.getItem(token);
}

export function setToken(value) {
    sessionStorage.setItem(token, JSON.stringify(value));
}

export function removeToken() {
    sessionStorage.removeItem(token);
}

export function clear() {
    sessionStorage.clear();
}
